Skip to content

Conversation

siversm
Copy link
Member

@siversm siversm commented Nov 11, 2026

Move the complete GraphQL schema and resolvers into server/schema.ts, so the API tests now run against the same code as the server. server/index.ts only seeds the database and starts the server.

Replace the four SQL branches in the pokemons resolver with one query built from a list of conditions, and remove the unused SORT_COLUMNS object and sort enums. Add API tests for ratePokemon, sorting by own rating, and combined filter, cursor and sort.

closes #60
Co Author: Pederoha, Copilot Luna 5.6

Move the complete GraphQL schema and resolvers into server/schema.ts,
so the API tests now run against the same code as the server.
server/index.ts only seeds the database and starts the server.

Replace the four SQL branches in the pokemons resolver with one query
built from a list of conditions, and remove the unused SORT_COLUMNS
object and sort enums. Add API tests for ratePokemon, sorting by own
rating, and combined filter, cursor and sort.

Issue: #60
Co Author: Pederoha, Copilot Luna 5.6
@pederoha pederoha marked this pull request as ready for review November 11, 2026 09:59
@pederoha pederoha requested a review from a team as a code owner November 11, 2026 09:59
Copy link
Member

@pederoha pederoha left a comment •

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job on separating out the schema, this makes the server code much easier to read, and the schema easier to understand!

@pederoha pederoha merged commit 5365a06 into dev Nov 11, 2026
Sign in to join this conversation on GitHub.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants